package com.example.demo;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import com.example.demo.property.FuckGirl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import org.springframework.web.bind.annotation.*;

import javax.xml.ws.RequestWrapper;

import static org.omg.IOP.TAG_ORB_TYPE.value;

/**
 * Created by lhl on 2017/7/4.
 */
@RestController
public class HelloController {

    @Autowired
    private FuckGirl fg ;

//    @Value("${cupSize}")
//    private String cupSize;
//
//    @Value("${age}")
//    private Integer age;
//
//    @Value("${content}")
//    private String content;

    @RequestMapping(value={"/hello","/hi"},method= RequestMethod.GET)
    public String say(){
//        return cupSize+age+content+"properties"+fg.getWater();
        return "properties"+fg.getWater();
    }

    @RequestMapping(value="varible/{id}",method= RequestMethod.GET)
    public String varible(@PathVariable("id") Integer id){

        return "id"+id;
    }
    @RequestMapping(value="/param",method= RequestMethod.GET)
    public String param(@RequestParam("id") Integer id){

        return "id"+id;
    }
}
